﻿using System;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace ProjetoComperio.DataLayer.Entities
{
    public class Comment
    {
        public Comment()
        {
            this.CommentID = 0;
            this.SubjectId = 0;
        }


        public virtual int CommentID { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Descrição")]
        public virtual string Description { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Usuário")]
        public virtual string UserName { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Email")]
        public virtual string Email { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Data criação")]
        public virtual DateTime CreatedDate { get; set; }
                
        public virtual int SubjectId { get; set; }
        public virtual Subject Subject { get; set; }
    }
}
